package main

import (
	"errors"
	"fmt"

	"main/config"
	"main/dao"
)

func init() {
	config.Connect()
}

func main() {
	var err error

	var te *dao.TestErr
	te, err = dao.FirstByID(4)
	if err != nil {
		if errors.Is(err, dao.NotFound) {
			fmt.Println(dao.NotFound)
			return
		}
		fmt.Println(err)
		return
	}

	fmt.Println("te:", *te)
}
